//
//  Parser.swift
//  Loop
//
//  Created by thomas on 2020/9/23.
//

import Foundation

class Parser {

    class func parse<T: Codable>(json: Data) -> T? {

        let model = try? JSONDecoder().decode(T.self, from: json)
        return model
    }
}
